# coding= utf-8

from aip import AipSpeech

APP_ID = '15588695'
API_KEY = 'denQ8XuE8RbBXUvR5dy15jsi'
SECRET_KEY = 'FihhQCFmeBQshbSAyG7XxDTx1rZ5Qiif'

client = AipSpeech(APP_ID,API_KEY,SECRET_KEY)

# 读取文件
def get_file_content(filePath):
    with open(filePath,'rb') as fp:
        return fp.read()


# 识别本地文件
result = client.asr(get_file_content('music.wav'),'wav',16000,{
    'dev_pid' : 1536,
})
print(result)
